package com.laogu.serviceweb.controller;

import com.laogu.serviceweb.biz.HelloBiz;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {
    @Autowired
    private HelloBiz helloBiz;

    @RequestMapping("/dubbo.do")
    public String toHello(@RequestParam(defaultValue = "你好") String msg) {
        System.out.println("-----------------------/dubbo.do-----------------------接口访问成功");
        helloBiz.sayHello(msg);
        return "hello";
    }

    @RequestMapping("/niubi.do")
    public String niubi() {
        return "hello";
    }

}
